#!/usr/bin/python
# -*- coding:utf-8 -*-
# @author  : micah
# @time    :  
# @function: 
# @version :


from selenium import webdriver
from selenium.common.exceptions import TimeoutException, NoSuchElementException
from selenium.webdriver.common.by import By


browser = webdriver.Chrome()

try:
    browser.get('https://www.baidu.com')

except TimeoutException:
    print('time out')


try:
    browser.find_element(By.ID, 'baic')
except NoSuchElementException:
    print('没有当前节点')
    # print(e)

browser.quit()
